#include<stdio.h>
int main()
{
	long long a, b;
	scanf_s("%lld %lld", &a, &b);
	int i = 1;
	while (1)
	{
		if (a * i % b == 0)
			break;
		i++;
	}
	printf("%lld", a * i);

	return 0;
}